/*	This is a message class (well, stuct) that is used to send "messages" to the AIs, and even the 
	player. For example, if the player attacks a computer, a message will be sent to the computer that
	says it's been attacked, and it will take the appropiate action (i.e. die). If it's the other way 
	around, the player's Update() function needs know that the player's been attacked so it can decrease
	his health.
	
	In case you're wondering, I'm getting this from my AI book. But I'm changing things around so it
	makes more sense. And getting rid of unneeded material. And adding my own if needed.

	Note: In the book, there was functionality for a delayed message. I didn't think we needed it so I 
	didn't add it in. If you want it, tell me. 
	*/

#pragma once
#include "MessageTypes.h"


struct Message
{
	int Sender; // The ID of the entity that sent this message. 
	int Receiver; // The ID of the entity that is to receive this message.

	/*	Message types are enumerated in "MessageTypes.h". This can be the difference between "attack", and
		"heal", so it's sorta important. */

	MessageType Type; 



	/*	And finally, we've got some extra info here. See, if a player attacked a monster, a message
		would be sent telling the monster that he's been attacked. But that message should proabably
		also include the player's attack stat, don't you think? */

	void* ExtraInfo;

	Message(): 	Sender(-1),
				Receiver(-1),
				Type()
	{}

	Message(int sender,
			int receiver,
			MessageType type,
			void* info = 0):Sender(sender),
							Receiver(receiver),
							Type(type),
							ExtraInfo(info)
	{}


};


